#ifndef VEC2_H
#define VEC2_H

namespace Engine
{
	class Vec2
	{
		public:
			float x, y;

			Vec2();

			Vec2(float _x, float _y);

			Vec2& operator +=(const Vec2& rhs);

			Vec2 operator+(const Vec2& rhs) const;

			Vec2& operator +=(float a);

			Vec2 operator+(float a) const;

			Vec2& operator -=(const Vec2& rhs);

			Vec2 operator-(const Vec2& rhs) const;

			Vec2& operator -=(float a);

			Vec2 operator-(float a) const;

			Vec2 operator-() const;

			Vec2& operator*=(float a);

			Vec2 operator*(float a) const;

			Vec2& operator*=(Vec2& rhs);

			Vec2 operator*(Vec2& rhs) const;

			bool IsEqualTo(Vec2& param);

			float& operator[](unsigned int index);


			const float* ToArray();

			float Length() const;

			void Normalize();

			float SquaredLength() const;
	};

	float DotProduct(const Vec2& a, const Vec2& b);
}

#endif